# coding=utf-8
from framework.base_page import BasePage
#订单列表页面一些操作
class EportsQuotationListPage(BasePage):
    btn_Advanced_search = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div/form/div[1]/div/div[2]/div/div[1]/a"
    btn_Hide = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div/form/div[2]/div[2]/div/div/div[1]/a"
    btn_search = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[2]/div/form/div[1]/div/div[2]/div/div[1]/button[2]"
    btn_search_ship = ""
    btn_search_port = ""
    btn_search_Agency = ""
    btn_search_serviceType = ""
    btn_search_orderNo = "xpath=>//*[@id='orderNumber']/div/div/div[1]"
    btn_search_orderStatus = "xpath=>//*[@id='status']/div/div"
    btn_order ="xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[3]/div/div[1]/div[1]/div[1]"
    dropDown_search_ship = ""
    dropDown_search_port = ""
    dropDown_search_Agency = ""
    dropDown_search_serviceType = ""
    dropDown_search_orderNo = "xpath=>//input[@id='orderNumber']"
    dropDown_search_orderStatus = "xpath=>//input[@id='status']"
    btn_inquir = "xpath=>//*[@id='root']/div/div/div/div[2]/div[2]/div/div[3]/div/div[1]/div/div[1]"

    def click_search_ship(self):
        self.click(self.btn_search_ship)
        self.sleep(2)

    def click_search_port(self):
        self.click(self.btn_search_port)
        self.sleep(2)

    def click_search_Agency(self):
        self.click(self.btn_search_Agency)
        self.sleep(2)

    def click_search_serviceclick(self):
        self.click(self.btn_search_serviceType)
        self.sleep(2)

    def click_search_orderNo(self):
        self.click(self.btn_search_orderNo)
        self.sleep(2)

    def click_search_orderStatus(self):
        self.click(self.btn_search_orderStatus)
        self.sleep(2)

    def click_order(self):
        self.click(self.btn_order)
        self.sleep(2)

    def dropDownType_search_ship(self,text):
        self.dropDownType(self.dropDown_search_ship,text)
        self.sleep(2)

    def dropDownType_search_port(self,text):
        self.dropDownType(self.dropDown_search_port,text)
        self.sleep(2)

    def dropDownType_search_Agency(self,text):
        self.dropDownType(self.dropDown_search_Agency,text)
        self.sleep(2)

    def dropDownType_search_serviceclick(self,text):
        self.dropDownType(self.dropDown_search_serviceType,text)
        self.sleep(2)

    def dropDownType_search_orderNo(self,text):
        self.dropDownType(self.dropDown_search_orderNo,text)
        self.sleep(2)

    def dropDownType_search_orderStatus(self,text):
        self.dropDownType(self.dropDown_search_orderStatus,text)
        self.sleep(2)

    def click_Advanced_search(self):
        self.click(self.btn_Advanced_search)
        self.sleep(2)

    def click_Hide(self):
        self.click(self.btn_Hide)
        self.sleep(2)

    def click_search(self):
        self.click(self.btn_search)
        self.sleep(2)

    def click_inquir(self):
        self.click(self.btn_inquir)
        self.sleep(2)
